﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace EasyCLRBase.AssemblyExplorer
{
    /// <summary>
    /// MEF mimic attribute class to use compatible structur for CLR creation. Since MEF do not support attribute for struct, this class become standalone.
    /// </summary>
    [AttributeUsage(AttributeTargets.Field, AllowMultiple = false)]
    public class ImportManyAttribute : Attribute
    {
        /// <summary>
        /// Imitation of the Contract Type of the MEF
        /// </summary>
        public Type ContractType { get; private set; }
        /// <summary>
        /// Initialize Import Attribute.
        /// </summary>
        /// <param name="contractType">Type of a import.</param>
        public ImportManyAttribute(Type contractType)
        {
            this.ContractType = contractType;
        }
    }
}
